package com.bookcode.dao;

import com.bookcode.entity.User;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

public interface UserRepository extends JpaRepository<User,Long> {


    @Query("from User c where c.username=:username")
    User findUserByName(@Param("username") String username);



}
